SftTree/NET 2.0

GetContents Method, SftTree Class

Softel vdm, Inc.

Returns the contents of the control in an XML document.

Syntax      SftTree Class (Softelvdm.SftTreeNET)

VB   

Public Shared Function GetContents( _
     ByVal SftTreeControl As SftTree, _
     ByVal contents As PersistContentsEnum _
  ) As XmlDocument

C#   

public static XmlDocument GetContents(
     SftTree SftTreeControl,
     PersistContentsEnum contents );

C++   

public: static XmlDocument^ GetContents(
     SftTree^ SftTreeControl,
     PersistContentsEnum contents );

contents

Defines processing options.

PersistContentsEnum

Value

Description

None

0

No data is transferred.

ItemsOnly

1

All item definitions are saved/loaded.

HeadersOnly

2

All header definitions are saved/loaded.

FootersOnly

4

All footer definitions are saved/loaded.

Contents

7

All content definitions (items, headers and footers) are saved/loaded.

Props

256

All control property definitions are saved/loaded.

All

65535

All definitions are saved/loaded.

SftTreeControl

Defines the SftTree/NET control whose contents are to be retrieved.

Return Value

An XML document containing the requested contents.

Comments

The GetContents method returns the contents of the control in an XML document.

Saving/loading the tree control contents using GetContents/SetContents saves/loads all data of the specified category (contents parameter). An application may wish to limit the amount of data saved by implementing its own save/load mechanism and save only the properties that are needed. Alternatively, if an application has an external data source, it may rebuild the tree control contents from its own data source, which may be significantly faster than an XML document. By implementing its own save/load mechanism an application could use a regular file or a custom format, which may also be significantly faster than an XML document.


Feedback / comments / error reports for this topic
© 2007 - Softel vdm, Inc. - www.softelvdm.com